#!/bin/bash

#remove deprecated files
sudo rm -f /etc/apt/sources.list.d/home:stevenpusser.list /etc/apt/trusted.gpg.d/home_stevenpusser.gpg

add_external_repo "stevenpusser" "https://download.opensuse.org/repositories/home:stevenpusser/Debian_10/Release.key" "http://download.opensuse.org/repositories/home:/stevenpusser/Debian_10/" "/" || exit 1

apt_update
if [ $? != 0 ]; then
  rm_external_repo "stevenpusser"
  error "Failed to perform apt update after adding stevenpusser repository."
fi

install_packages palemoon || exit 1
